package com.xiaouyudeguang.common.annotation;

import org.springframework.core.annotation.AliasFor;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import java.lang.annotation.*;

@Target(ElementType.METHOD)
@Retention(RetentionPolicy.RUNTIME)
@Documented
@RequestMapping
public @interface ApiMapping {

    @AliasFor(annotation = RequestMapping.class)
    String value();

    @AliasFor(annotation = RequestMapping.class)
    RequestMethod[] method() default {};

    String tags();

    /**
     * 描述
     *
     * @return
     */
    String notes() default "";

    /**
     * 是否开放
     *
     * @return
     */
    boolean isOpen() default true;
}